package day20171102;

import java.util.Scanner;
public class Test {
    public static void main(String[] args) {
        int a = 0;
        int b = 0;
        while (true) {
            Scanner scanner = new Scanner(System.in);
            System.out.println("Please input 1st int:");
            a = scanner.nextInt();

            System.out.println("Please input 2nd int:");
            b = scanner.nextInt();
            int c = 0;
            try {
                c = a / b;
            } catch (ArithmeticException e) {
                //int c = a / b;
                System.out.println("除数为零！");
                System.out.println(a + "/" + b + "=" + c);
            }
        }
    }
}